package com.fsds.crem.web.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.fsds.crem.web.dao.EmailMessageDao;
import com.fsds.crem.web.entity.EmailMessage;
import com.fsds.crem.web.service.EmailMessageService;

@Service("emailMessageService")
public class EmailMessageServiceImpl implements EmailMessageService {

	@Resource
	private EmailMessageDao emailMessageDao;
	
	@Override
	public List<EmailMessage> findEmailMessageByState(EmailMessage emailMessage) {

		return emailMessageDao.findEmailMessageByState(emailMessage);
	}

	@Override
	public void updateEmailMessageStateById(EmailMessage emailMessage) {
		
		emailMessageDao.updateEmailMessageState(emailMessage);
	}

	@Override
	public void createEmailMessage(EmailMessage emailMessage) {
		
		emailMessageDao.create(emailMessage);
	}

	

}
